<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript" src="../js/jquery-3.3.1.min.js"></script>
</head>
<body>
<input type="text" id="baidu"><input type="button" value="百度三下" onclick="Baidu()">
<br><br>
<ul id="ul">

</ul>
</body>
</html>
<script type="text/javascript">
    function Baidu() {
            var wd =  $("#baidu").val();
            $.ajax({
                url:"https://www.baidu.com/sugrec?prod=pc&wd=" + wd + "&cb=zxc",
                type:"get",
                data:"",
                dataType:"jsonp",
                jsonpCallback: "jsonpProcess",
                success:function () {

                }

            });
    }
    function zxc(data) {
        console.log(data)
        var g = data.g || [];
        var html = '';
        $.each(g,function (a,b) {
            html += `<li><a href="https://www.baidu.com/s?wd=${encodeURI(b.q)}">${b.q}</a><br/></li>`;
        });
        $("#ul").append(html)
    }
</script>